using System;

namespace Caramel
{
	[Serializable()]
	public struct DateRange
	{
		private DateTime _start;
		private DateTime _end;

		public DateRange(DateTime start, DateTime end)
		{
			//_start = Guard.IsTrue(start, start < end, () => { throw new ArgumentOutOfRangeException("start", "Start must be before end."); });
			_start = start;
			_end = end;
		}

		public DateTime Start { get { return _start; } }

		public DateTime End { get { return _end; } }

		public TimeSpan Span { get { return this.End - this.Start; } }
	}
}
